﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.ServiceModel.Dispatcher;
using System.ServiceModel.Channels;

namespace SLLottery.Common
{
    public class MessageInspector : IClientMessageInspector
    {
        public static string MyCustomHeaderContent
        {
            get;
            set;
        }

        public void AfterReceiveReply(ref System.ServiceModel.Channels.Message reply, object correlationState)
        {
			
        }

        public object BeforeSendRequest(ref System.ServiceModel.Channels.Message request, System.ServiceModel.IClientChannel channel)
        {
            request.Headers.Add(MessageHeader.CreateHeader("username", "", "7692AA70EEF92B42"));
            request.Headers.Add(MessageHeader.CreateHeader("password", "", "00E19868F0C755F0"));
            return null;
        }
    }
}
